efi: Disable secure boot if shim is in insecure mode
authorJosh Boyer <jwboyer@fedoraproject.org>
Wed, 6 Feb 2013 00:25:05 +0000 (19:25 -0500)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 12 Jan 2017 15:52:37 +0000 (15:52 +0000)
commitb175d8dee297de67bb1fb430d5231bc187082c74
tree500451c64527c16b3861ed30f4b3607bcca9a0cd
parente5d8c01ae90246ceff41e6904e6c7cf150761b98
efi: Disable secure boot if shim is in insecure mode

A user can manually tell the shim boot loader to disable validation of
images it loads.  When a user does this, it creates a UEFI variable called
MokSBState that does not have the runtime attribute set.  Given that the
user explicitly disabled validation, we can honor that and not enable
secure boot mode if that variable is set.

Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org>
Gbp-Pq: Topic features/all/securelevel
Gbp-Pq: Name efi-disable-secure-boot-if-shim-is-in-insecure-mode.patch
arch/x86/boot/compressed/eboot.c
include/linux/efi.h